class BD_MainMenu extends GFxMoviePlayer;

var GFxClikWidget StartButton;
var GFxObject MainMenuTitle;
var GFxClikWidget ExitButton;

function bool Start(optional bool StartedPuased = false)
{
	super.Start();
	Advance(0);


	return true;
}

event bool WidgetInitialized(name Widgetname, name WidgetPathh, GFxObject Widget)
{
	switch(WidgetName)
	{
	case('startBTN'):
		StartButton = GFxClikWidget(Widget);
		StartButton.AddEventListener('CLIK_press', OnStartButtonPress);
		break;
	case('exitBTN'):
		ExitButton = GFxClikWidget(Widget);
		ExitButton.AddEventListener('CLIK_press', OnExitButtonPress);
		break;
	default:
		break;
	}
	return true;
}

function OnStartButtonPress(GFxClikWidget.EventData ev)
{
	ConsoleCommand("open 16_CastleSanctum_Prototype");
}

function OnExitButtonPress(GfxClikWidget.EventData ev)
{

	ConsoleCommand("quit");
}



defaultproperties
{
	WidgetBindings.Add((WidgetName="startBtn",WidgetClass=class'GFxClikWidget'))
	WidgetBindings.Add((WidgetName="ExitBtn",WidgetClass=class'GFxClikWidget'))
}

